package net.yeah.mickey_zhouyou.util.fcs.elem;

import javax.script.ScriptContext;

import net.yeah.mickey_zhouyou.util.fcs.serialize.IConvertor;

public class ConditionAnd extends ConditionSelector {
	private ConditionSelector firstCondition;
	private ConditionSelector secondCondition;

	public ConditionAnd(ConditionSelector firstCondition,
			ConditionSelector secondCondition) {
		super();
		this.firstCondition = firstCondition;
		this.secondCondition = secondCondition;
	}

	@Override
	public Object select(Object obj, IConvertor objConvertor,
			ScriptContext context) {
		obj = this.firstCondition.select(obj, objConvertor, context);
		obj = this.secondCondition.select(obj, objConvertor, context);
		return obj;
	}

}
